package bigbrother.log;

import bigbrother.log.daylog.DayLog;
import bigbrother.log.daylog.DayLogId;
import bigbrother.log.logentries.LogEntry;

/**
 * Represents a log of the conversation in a the IRC channels the bot has been recording.
 * <p/>
 * Allows adding lines, or reading lines based on the date and time or line number.
 *
 * @author Hans Haggstrom
 */
public interface Log
{

    /**
     * @param dayLogId an ID including the day and the channel to get the log for.
     *
     * @return the log for the specified day and channel.  Will be an empty DayLog if there is no logs for the specified
     *         channel and date.
     */
    DayLog getDay( DayLogId dayLogId );

    /**
     * @param message the message to add.  Should not be null. The message contains information on what channel it
     *                happened in and what time it happened.
     */
    void appendEntry( LogEntry message );

}
